<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="/WEB-INF/jsp/taglib.jsp"%>
<%@ taglib prefix="ec" uri="/WEB-INF/taglib/extremecomponents.tld" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
  <link href="css/norm.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
body {
	background-image: url(images/bg.gif);
}
-->
</style>
  	<TITLE>WordSparrow</TITLE>
	<link rel="stylesheet" type="text/css" href="css/extremecomponents.css">
	<SCRIPT type="text/javascript">
	function modifyUser(value) {
	        //var bln = window.confirm("确定要修改吗？", "确定", "取消");
	        //if(bln == true) {
	        var page=document.all.ec_p.value;
			url = "group.htm?action=tomodify&flag=mod&groupid=" + value+"&page="+page;
			document.location.href = url;
			//}
		}
	
	function changeState(value) {
		var bln = window.confirm("确定要删除此用户组吗？", "确定", "取消");
		if(bln == true) {
		    var page=document.all.ec_p.value;
			url = "group.htm?action=delete&groupid=" + value+"&page="+page;
			document.location.href = url;
		}
	}
	</SCRIPT>
</head>
  
  <body>
  <table width="100%" border="0" cellpadding="0" cellspacing="0">
  <tr>
    <td><table width="100%" border="0" cellpadding="0" cellspacing="0">
      <tr>
        <td><table width="100%" border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td bgcolor="#FFFFFF" class="gj">
     <table width="100%" border="0" cellpadding="0" cellspacing="0">
                  <tr>
                    <td width="22" align="left"><img src="images/arrow2.gif" width="22" height="20"></td>
                    <td bgcolor="#7AAED6" class="normtit">用户组管理-<a href="group.htm?action=tomodify&flag=add">添加用户组</a></td>
                    <td width="8" align="right"><img src="images/arrow3.gif" width="8" height="20"></td>
                  </tr>
                </table>              
    <ec:table 
  		items="list"
  		var="group"
  		action="${pageContext.request.contextPath}/group.htm?action=list"
  		imagePath="${pageContext.request.contextPath}/images/table/compact/*.gif"
  		title="用户组列表<br><br><font color=\"red\">提示：在下面相应文本框中输入查询条件，然后点击查询按钮，即可进行查询操作;点击表头，列表将按照相应项排序后显示</font>"
  		view="compact"
  		rowsDisplayed="10">
  		<ec:exportXls
           fileName="output.xls" 
           tooltip="Export Excel"
           text="XLS"
           />
  		<ec:row highlightRow="true">
   			<ec:column property="modify" title="修改" filterable="false" sortable="false">
   			<a href="#" onclick="modifyUser('<c:out value='${group.groupid}'/>');"><img src="images/modify.gif"/></a>
            </ec:column>
   			<ec:column property="delete" title="删除" filterable="false" sortable="false">
               <a href="#" onclick="changeState('<c:out value='${group.groupid}'/>');"><img src="images/delete.gif"/></a>
            </ec:column>
   			<ec:column property="groupname" title="用户组名称"/>
   			<ec:column property="groupdes" title="用户组描述"/>
  		</ec:row>
	</ec:table>
	</td>
          </tr>
        </table></td>
      </tr>
    </table></td>
  </tr>
</table>
  </body>
</html>
